package team.seekers.oj.codetest.dto;

import lombok.*;
import org.hibernate.validator.constraints.Length;
import team.seekers.oj.common.entity.BaseDTO;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.util.List;

@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode(callSuper = true)
public class CodeTestCreateReqDTO extends BaseDTO {
    @Length(max = 60, message = "标题最大长度为 60")
    @NotBlank
    private String name;

    private Integer isPublic;

    private Long userId;

    @NotNull
    private Integer type;

    @Size(max = 1024, message = "最多支持 1024 个题目加入题单")
    private List<Long> problems;           // List<problemId>
}
